package com.ysd.lis.controller.bac;


import com.ysd.common.Result;
import com.ysd.lis.controller.pub.BaseController;
import com.ysd.lis.entity.bac.BacWorkFlowNodeDict;
import com.ysd.lis.request.BacWorkFlowNodeDictDto;
import com.ysd.lis.service.bac.BacWorkFlowNodeDictService;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * <p>
 * 前端控制器
 * </p>
 *
 * @author cfz
 * @since 2024-04-09
 */
@RestController
@RequestMapping("/api/bac/bac-work-flow-node-dict")
public class BacWorkFlowNodeDictController extends BaseController {
    @Autowired
    BacWorkFlowNodeDictService bacWorkFlowNodeDictService;

    @ApiOperation("查询")
    @GetMapping("/findBacWorkFlowNodeDictList")
    public Result findBacWorkFlowNodeDictList(BacWorkFlowNodeDict bacWorkFlowNodeDict) {
        return bacWorkFlowNodeDictService.findBacWorkFlowNodeDictList(bacWorkFlowNodeDict);
    }

    @ApiOperation("增加")
    @PostMapping("/addBacWorkFlowNodeDict")
    public Result addBacWorkFlowNodeDict(@RequestBody BacWorkFlowNodeDict bacWorkFlowNodeDict) {
        return bacWorkFlowNodeDictService.addBacWorkFlowNodeDict(bacWorkFlowNodeDict);
    }

    @ApiOperation("删除")
    @PostMapping("/deleteBacWorkFlowNodeDict")
    public Result deleteBacWorkFlowNodeDict(@RequestBody BacWorkFlowNodeDictDto bacWorkFlowNodeDictDto) {
        return bacWorkFlowNodeDictService.deleteBacWorkFlowNodeDict(bacWorkFlowNodeDictDto);
    }

    @ApiOperation("修改")
    @PostMapping("/updateBacWorkFlowNodeDict")
    public Result updateBacWorkFlowNodeDict(@RequestBody BacWorkFlowNodeDict bacWorkFlowNodeDict) {
        return bacWorkFlowNodeDictService.updateBacWorkFlowNodeDict(bacWorkFlowNodeDict);
    }
}
